# Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

# NOTE: This file is auto generated by the elixir code generator program.
# Do not edit this file manually.

defmodule GoogleApi.Dataflow.V1b3.Model.SeqMapTask do
  @moduledoc """
  Describes a particular function to invoke.

  ## Attributes

  *   `inputs` (*type:* `list(GoogleApi.Dataflow.V1b3.Model.SideInputInfo.t)`, *default:* `nil`) - Information about each of the inputs.
  *   `name` (*type:* `String.t`, *default:* `nil`) - The user-provided name of the SeqDo operation.
  *   `outputInfos` (*type:* `list(GoogleApi.Dataflow.V1b3.Model.SeqMapTaskOutputInfo.t)`, *default:* `nil`) - Information about each of the outputs.
  *   `stageName` (*type:* `String.t`, *default:* `nil`) - System-defined name of the stage containing the SeqDo operation. Unique across the workflow.
  *   `systemName` (*type:* `String.t`, *default:* `nil`) - System-defined name of the SeqDo operation. Unique across the workflow.
  *   `userFn` (*type:* `map()`, *default:* `nil`) - The user function to invoke.
  """

  use GoogleApi.Gax.ModelBase

  @type t :: %__MODULE__{
          :inputs => list(GoogleApi.Dataflow.V1b3.Model.SideInputInfo.t()) | nil,
          :name => String.t() | nil,
          :outputInfos => list(GoogleApi.Dataflow.V1b3.Model.SeqMapTaskOutputInfo.t()) | nil,
          :stageName => String.t() | nil,
          :systemName => String.t() | nil,
          :userFn => map() | nil
        }

  field(:inputs, as: GoogleApi.Dataflow.V1b3.Model.SideInputInfo, type: :list)
  field(:name)
  field(:outputInfos, as: GoogleApi.Dataflow.V1b3.Model.SeqMapTaskOutputInfo, type: :list)
  field(:stageName)
  field(:systemName)
  field(:userFn, type: :map)
end

defimpl Poison.Decoder, for: GoogleApi.Dataflow.V1b3.Model.SeqMapTask do
  def decode(value, options) do
    GoogleApi.Dataflow.V1b3.Model.SeqMapTask.decode(value, options)
  end
end

defimpl Poison.Encoder, for: GoogleApi.Dataflow.V1b3.Model.SeqMapTask do
  def encode(value, options) do
    GoogleApi.Gax.ModelBase.encode(value, options)
  end
end
